<?php

class Application_Form_IncidentUpdating extends Application_Form_Incident
{
	public function init() {
		parent::init();

		Zend_Loader::loadfile('SituationSelect.php',APPLICATION_PATH.'/forms/element/',false);
		$situation = new Application_Form_Element_SituationSelect('idSituation',array('onchange' => 'toggleElements();'));
		$situation->setLabel("Situation");
					

		$dateResolution=new ZendX_JQuery_Form_Element_DatePicker(
                        'dateResolution',
		array('label' => 'Date:','jQueryParams' => array('dateFormat' => 'yy-mm-dd'))
		);

		$cout=new Zend_Form_Element_Text('cout');
		$cout->setLabel("Cout de l'intervention")
		->addFilter('StripTags')
		->addFilter('StringTrim');

		$solution=new Zend_Form_Element_Text('solution');
		$solution->setLabel("Solution utilisee")
		->addFilter('StripTags')
		->addFilter('StringTrim');
			
		$this->addElements(array($situation,$dateResolution,$cout,$solution));
		$this->addDisplayGroup(array('dateResolution', 'cout','solution'), 'hiddenElements');
		$displayGroup=$this->getDisplayGroup('hiddenElements');


		$displayGroup->removeDecorator('Fieldset');
		$displayGroup->removeDecorator('HtmlTag');
		$displayGroup->removeDecorator('DtDdWrapper');
		$displayGroup->addDecorator('HtmlTag',array('tag'=>'div','id'=>'hiddenElements'));
		
	}



}

